import App from './App'
import Vue from 'vue'
import store from '@/store/index.js'
import moment from '@/common/moment.js';
import utilsMixin from "@/mixin/utilsMixin.js"
Vue.mixin(utilsMixin)

Vue.config.productionTip = false;
Vue.prototype.$store = store;
Vue.prototype.$moment = moment;
App.mpType = 'app'

import uView from "@/uni_modules/uview-ui";
Vue.use(uView);

let onFun = uni.$on;
uni.$on = (eventName, obj) => {
	try {
		uni.$off(eventName);
	} catch (error) {}
	onFun(eventName, obj);
}

const app = new Vue({
	store,
	...App,
})

require('@/utils/request.js')(app)

app.$mount()

export default app